<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <title>使用循环语句将一系列华氏温度转换为摄氏温度</title>
</head>
<body>
<script>
    var degreesFahrenheitCollection = [212, 32, -459.15];
    var degreesCentigradeCollection = [];
    var loopCounter;
    for (loopCounter = 0; loopCounter <= 2; loopCounter++) {
        degreesCentigradeCollection[loopCounter] = 5 / 9 * (degreesFahrenheitCollection[loopCounter] - 32);
    }
    for (loopCounter = 2; loopCounter >= 0; loopCounter--) {
        document.write('Value ' + loopCounter + ' was ' + degreesFahrenheitCollection[loopCounter] + ' degrees Fahrenheit');
        document.write(' which is ' + degreesCentigradeCollection[loopCounter] + ' degrees centigrade<br/>');
    }
</script>
</body>
</html>